package com.xrs.xrseducation.course.controller;


import com.xrs.xrseducation.course.entity.Course;
import com.xrs.xrseducation.course.entity.CourseExt;
import com.xrs.xrseducation.course.service.ICourseService;
import com.xrs.xrseducation.course.service.impl.CourseServiceImpl;
import com.xrs.xrseducation.outline.entity.Outline;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author jobob
 * @since 2020-09-18
 */
@RestController
@RequestMapping("/course/course")
public class CourseController {

    @Autowired
    CourseServiceImpl courseService;

    /**
     * 查询
     */
    @RequestMapping("/queryAll")
    public void queryAll(){

    }

    /**
     * 添加
     */
    @RequestMapping("/addCourse")
    public void addCourse(CourseExt courseExt){
        courseService.addCourse(courseExt);
    }

    /**
     * 修改
     */
    @RequestMapping("/updateCourse")
    public void updateCourse(CourseExt courseExt){
        courseService.updateCourse(courseExt);
    }

    /**
     * 删除
     */
    @RequestMapping("/deleteCourse")
    public void deleteCourse(Course course){
        courseService.deleteCourse(course);
    }
}

